home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Top 200 Programs
/
Top 200 Programs.iso
/
Bob8
/
THOMPSON
/
LIBERTY
/
PRODUCT
/
LB14W.EXE
/
WINRECT.BAS
< prev
Wrap
BASIC Source File
|
1996-02-02
|
718b
|
28 lines
'WINRECT.BAS - show how to get window position and size
'and demonstrate how to use the struct statement
struct winRect, _
orgX as uShort, _
orgY as uShort, _
cornerX as uShort, _
cornerY as uShort
open "test me" for window as #win
open "user.dll" for dll as #user
hndl = hwnd(#win)
calldll #user, "GetWindowRect", _
hndl as word, _
winRect as struct, _
result as void
print "Upper Left corner of 'test me' is: "; winRect.orgX.struct; ", "; winRect.orgY.struct
print "Lower Right corner of 'test me' is: "; winRect.cornerX.struct; ", "; winRect.cornerY.struct
close #user
input r$